

<template>
  <div>
    <v-header></v-header>
  <!--<div>-->
    <!--左边点击查看医生的模态-->

    <!--内容区-->
    <div class="ris_cont clear">
      <div class="reading_l_l_modal">
        <div class="reading_l_l_modal_cont">
          <div class="reading_modal_head">报告医生列表<button class="button reading_l_l_modal_close">X</button></div>
          <div class="reading_modal_contList">
            <div>
              <p>张涛</p>
              <p>医生</p>
              <p><button class="button btn_blur">发送</button></p>
            </div>
            <div>
              <p>张涛</p>
              <p>医生</p>
              <p><button class="button btn_blur">发送</button></p>
            </div>
            <div>
              <p>张涛</p>
              <p>医生</p>
              <p><button class="button btn_blur">发送</button></p>
            </div>
            <div>
              <p>张涛</p>
              <p>医生</p>
              <p><button class="button btn_blur">发送</button></p>
            </div>
            <div>
              <p>张涛</p>
              <p>医生</p>
              <p><button class="button btn_blur">发送</button></p>
            </div>
          </div>
        </div>
      </div>
      <!--左边-->
      <!--<div class="reading_left">-->
        <!--<div class="reading_left_top">-->
          <!--<p class=""></p>-->
          <!--<span>已检人员列表</span>-->
        <!--</div>-->
        <!--<div class="reg_search">-->
          <!--<table class="reg_search_table">-->
            <!--<tr>-->
              <!--<td>姓名</td>-->
              <!--<td><input type="text"></td>-->
              <!--<td>编号</td>-->
              <!--<td><input type="text"></td>-->
              <!--<td>检查部位</td>-->
              <!--<td>-->
                <!--<select>-->
                  <!--<option></option>-->
                  <!--<option v-for="type in partList" :value="type.id">{{type.name}}</option>-->
                <!--</select>-->
              <!--</td>-->
            <!--</tr>-->
            <!--<tr>-->
              <!--<td>类型</td>-->
              <!--<td>-->
                <!--<select>-->
                  <!--<option></option>-->
                  <!--<option v-for="type in eqptypeList" :value="type.id">{{type.name}}</option>-->
                <!--</select>-->
              <!--</td>-->
              <!--<td>设备</td>-->
              <!--<td>-->
                <!--<select>-->
                  <!--<option></option>-->
                  <!--<option v-for="type in equipList" :value="type.id">{{type.name}}</option>-->
                <!--</select>-->
              <!--</td>-->
              <!--<td>图像数量</td>-->
              <!--<td>-->
                <!--<input type="text" class="rep_Img_num">-->
                <!--<span class="rep_Img_num_text">至</span>-->
                <!--<input type="text" class="rep_Img_num">-->
              <!--</td>-->
            <!--</tr>-->
            <!--<tr>-->
              <!--<td>起始时间</td>-->
              <!--<td colspan="4">-->
                <!--<input type="date" class="reg_search_input"/>-->
                <!--<span class="reg_search_span">至</span>-->
                <!--<input type="date" class="reg_search_input"/>-->
              <!--</td>-->
              <!--<td><button class="reading_search button btn_yellow ">查询</button></td>-->
            <!--</tr>-->
          <!--</table>-->
        <!--</div>-->
        <!--<div class="reading_left_list">-->
          <!--<table class="reading_left_tableHead line_height_32">-->
            <!--<thead>-->
            <!--<tr class="color_white">-->
              <!--<th>姓名</th>-->
              <!--<th>性别</th>-->
              <!--<th>年龄</th>-->
              <!--<th>检查状态</th>-->
              <!--<th>拍片时间</th>-->
              <!--<th>操作</th>-->
            <!--</tr>-->
            <!--</thead>-->
          <!--</table>-->
          <!--<div class="reading_left_tableCont">-->
            <!--<table class="table line_height_32">-->
              <!--<tbody>-->
              <!--<tr>-->
                <!--<td>-->
                  <!--<div style="position: relative">-->
                    <!--<span class="color_red reading_tishiText">[急]<img src="./zhixiang_03.png"/></span>李四-->
                  <!--</div>-->
                <!--</td>-->
                <!--<td>男</td>-->
                <!--<td>33</td>-->
                <!--<td>未拍片</td>-->
                <!--<td>2017/02/15 08:16</td>-->
                <!--<td><button class="button">查看</button></td>-->
              <!--</tr>-->
              <!--<tr>-->
                <!--<td><span class="color_blur reading_tishiText">[急]<img src="./zhixiang_03.png"/></span>李四</td>-->
                <!--<td>男</td>-->
                <!--<td>33</td>-->
                <!--<td>未拍片</td>-->
                <!--<td>2017/02/15 08:16</td>-->
                <!--<td><button class="button">查看</button></td>-->
              <!--</tr>-->
              <!--<tr>-->
                <!--<td><span class="color_blur reading_tishiText">[急]<img src="./zhixiang_03.png"/></span>李四</td>-->
                <!--<td>男</td>-->
                <!--<td>33</td>-->
                <!--<td>未拍片</td>-->
                <!--<td>2017/02/15 08:16</td>-->
                <!--<td><button class="button">查看</button></td>-->
              <!--</tr>-->
              <!--</tbody>-->
            <!--</table>-->
          <!--</div>-->
        <!--</div>-->
      <!--</div>-->

      <!--左边-->
      <div class="reading_left">
        <div class="reading_left_top">
          <p class=""></p>
          <span>已检人员列表</span>
        </div>
        <div class="reg_search">
          <table class="reg_search_table">
            <tr>
              <td>姓名</td>
              <td><input type="text" v-model="name"></td>
              <td>编号</td>
              <td><input type="text" v-model="pid"></td>

            </tr>
            <tr>

              <td>设备类型</td>
              <td>
                <select v-model="eqpType" @change="getpartsByType(eqpType)">
                  <option></option>
                  <option v-for="type in eqptypeList" :value="type.name">{{type.name}}</option>

                </select>
                <!--<select v-model="eqpCode" style="display: none">-->
                  <!--<option v-for="type in eqptypeList" :value="type.code"></option>-->
                <!--</select>-->
              </td>
              <td>检查部位</td>
              <td>
                <!--<input type="text" v-model="parts">-->
                <select v-model="parts">
                <option></option>
                <option v-for="type in partList" :value="type.name">{{type.name}}</option>

                </select>
              </td>
            </tr>
            <tbody class="reg_search_tabToggle">
            <tr>
              <td>设备</td>
              <td>
                <select v-model="eqpName">
                <option></option>
                <option v-for="type in equipList" :value="type.name">{{type.name}}</option>
                </select>
              </td>
              <td>图像数量</td>
              <td>
                <input type="text" style="width: 40%;" v-model="beginnum">
                <span>至</span>
                <input type="text" style="width: 40%;" v-model="endnum">
              </td>
            </tr>
            <tr>
              <td>起始时间</td>
              <td colspan="3">
                <input type="date" v-model="begintime" class="width_50"/><input type="time" v-model="beginhour" class="width_50" />
              </td>
            </tr>
            <tr>
              <td>结束时间</td>
              <td colspan="3">
                <input type="date" v-model="endtime" class="width_50"/><input type="time" v-model="endhour" class="width_50"/>
              </td>
            </tr>
            </tbody>
            <tr>
              <td  class="click_zk">点击展开</td>
              <td colspan="3" class="reading_search"><button class="button btn_yellow aaa" @click="getListByCondition">查询</button></td>
            </tr>
          </table>
        </div>
        <div class="reading_left_list" v-loading="loading">
          <!--<table class="reading_left_tableHead line_height_32">-->
          <!---->
          <!--</table>-->
          <div class="reading_left_tableCont scroll2">
            <table class="table line_height_32">
              <thead>
              <tr class="color_white">
                <th style="width: 70px;">操作</th>
                <th>个人信息</th>
                <th>检查类型</th>
                <th>拍片时间</th>
                <th>检查部位</th>
                <th>图片数量</th>
              </tr>
              </thead>
              <tbody>
              <tr v-for="(pat,index) in patInfoList" @click="getResultDetail(pat)">
                <td><button class="button reading_left_tableCont_button" @click="imagesearch(pat)">查看</button></td>
                <td>
                  <div style="position: relative">
                    <span class="color_red" v-if="pat.emergstatus=='紧急'">[急]</span><span class="color_blur" v-else>[普]</span>{{pat.cname}}&nbsp;{{pat.sex}}&nbsp;{{pat.age}}
                  </div>
                </td>
                <td style="display: none">{{pat.id}}</td>
                <td style="display: none">{{pat.areacode}}</td>
                <td>{{pat.eqptypename}}</td>
                <td>{{pat.studate}}</td>
                <td>{{pat.partname}}</td>
                <td>{{pat.imagecount}}</td>
                <!--<td><button class="button reading_left_tableCont_button">查看</button></td>-->
              </tr>
              </tbody>
              <!--<tbody class="reading_left_tableCont_abs">-->
                <!--<tr v-for="(pat,index) in patInfoList">-->
                  <!--<td><button class="button reading_left_tableCont_button" @click="imagesearch(pat)">查看</button></td>-->
                <!--</tr>-->
              <!--</tbody>-->
            </table>
          </div>
        </div>
      </div>
      <!--右边-->
      <div class="reading_right">
        <div class="reading_right_head">
          <ul class="table_page">
            <li class="reading_table_page_active" @click="table_pageTitle(0)">书写报告</li>
            <li  @click="table_pageTitle(1)" style="display: none">补充登记信息</li>
            <li  @click="table_pageTitle(2)">报告流程</li>
          </ul>
        </div>

        <div class="reading_right_center">
          <!--书写报告-->
          <div class="writeReport">
            <!--左边-->
            <div class="reading_right_center_left">
              <div class="reading_r_c_l_top">
                <h1>影像检查描述</h1>
                <textarea v-model="description" :disabled="status==20||status==25||status==30"></textarea>
              </div>
              <div class="reading_r_c_l_center">
                <h1>
                  影像检查结论
                  <p>
                    阴阳性：
                    <select v-model="positive" :disabled="status==20||status==25||status==30">
                      <option value=""></option>
                      <option value=1>阳性</option>
                      <option value=0>阴性</option>
                    </select>
                    危急值：
                    <select v-model="emerg" :disabled="status==20||status==25||status==30">
                      <option value=""></option>
                      <option value="不危急">不危急</option>
                      <option value="危急">危急</option>
                    </select>
                    <button class="button btn_blur" style="display: none">危急值登记</button>
                  </p>
                </h1>
                <textarea v-model="result" :disabled="status==20||status==25||status==30"></textarea>
              </div>
              <div class="reading_r_c_l_bottom">
                <input v-model="resultid" style="display: none"/>
                <input v-model="status" style="display: none"/>
                <input v-model="patpid" style="display: none"/>
                <input v-model="recordno" style="display: none"/>
                <input v-model="areacode" style="display: none"/>
                <h1>影像建议</h1>
                <textarea v-model="advice" :disabled="status==20||status==25||status==30"></textarea>
              </div>
              <div class="reading_r_c_l_footInput">
                <table>
                  <tr>
                    <td>报告日期</td>
                    <td><input type="date" v-model="repTime" :disabled="status==20||status==25||status==30"/></td>
                    <td>检查医生</td>
                    <td>
                      <!--<select v-model="repuserCode" :disabled="status==20||status==25||status==30">-->
                        <!--<option></option>-->
                        <!--<option v-for="type in userList" :value="type.code">{{type.name}}</option>-->
                      <!--</select>-->
                      <div class="drop_down_Top drop_down_Top1">
                        <input type="text" v-model="searchRepUser" @click="showRepUser=true"  :disabled="status==20||status==25||status==30"/>
                        <ul class="top" v-show="showRepUser">
                          <li @click="selectRepUser({code:'',name:''})">&nbsp;</li>
                          <li v-for="type in userList" v-if="type.name.indexOf(searchRepUser)>=0" @click="selectRepUser(type)">{{type.name}}</li>
                        </ul>
                      </div>
                    </td>
                  </tr>
                  <tr>
                    <td>审核日期</td>
                    <td><input type="date" v-model="auditTime" :disabled="status==20||status==25||status==30"/></td>
                    <td>审核医生</td>
                    <td>
                      <!--<select v-model="audituserCode" :disabled="status==20||status==25||status==30">-->
                        <!--<option></option>-->
                        <!--<option v-for="type in userList" :value="type.code">{{type.name}}</option>-->
                      <!--</select>-->
                      <div class="drop_down_Top drop_down_Top2">
                        <input type="text" v-model="searchAutiUser" @click="searchAutiUserClick"  :disabled="status==20||status==25||status==30"/>
                        <ul class="top" v-show="showAutiUser">
                          <li @click="selectAutiUser({code:'',name:''})">&nbsp;</li>
                          <li v-for="type in userList" v-if="type.name.indexOf(searchAutiUser)>=0" @click="selectAutiUser(type)">{{type.name}}</li>
                        </ul>
                      </div>
                    </td>
                  </tr>
                </table>
              </div>
            </div>
            <!--右边-->
            <div class="reading_right_center_right">
              <div class="reading_r_c_r_top ">
                <p></p>
                <span class="reading_right_click">报告模板</span>
                <div class="reading_r_c_r_top_cont">
                  <input type="text" class="reading_r_c_r_top_cont_search "/>
                  <img src="../../../static/img/reportview/reading_search_03.png" class="reading_search_03"/>
                  <div class="tree_down_parent">
                    <ul class="tree_down">
                      <li v-for="(partgroup,index1) in baseTemplateList">
                        <a @click="toggle($event)"><img src="../../../static/img/reportview/fuhao_07.png">{{partgroup.name}}</a>
                        <ul>
                          <li v-for="(part,index2) in partgroup.partList">
                            <a @click="toggle($event)"><img src="../../../static/img/reportview/fuhao_07.png">{{part.name}}</a>
                            <ul>
                              <li v-for="(template,index3) in part.templateList">
                                <a @dblclick="addorreplace(index1,index2,index3)" :title="template.description+':'+template.result">{{template.title}}</a>
                              </li>
                            </ul>
                          </li>
                        <!--  <li>
                            <a><img src="./fuhao_07.png">二级菜单</a>
                            <ul>
                              <li><a><img src="./fuhao_07.png">三级菜单</a></li>
                            </ul>
                          </li>-->
                        </ul>
                      </li>
                    </ul>
                  </div>
                  <div class="tree_down_footCheck">
                    <label><input type="radio" name="=aa" v-model="addOrReplace" value="replace" :disabled="status==20||status==25||status==30"/>替换模板</label>
                    <label><input type="radio" name="=aa" v-model="addOrReplace" value="add" :disabled="status==20||status==25||status==30"/>追加模板</label>
                  </div>
                </div>
              </div>
              <div class="reading_r_c_r_bottom ">
                <p></p>
                <span class="reading_right_click" @click="gethistory()">历史报告</span>
                <div class="reading_r_c_r_bottom_cont">
                  <div class="reading_r_c_r_bottom_cont_time">
                    <label><input type="radio" v-model="checktime" value="3" name="time" @change="gethistory"/>三个月</label>
                    <label><input type="radio"  v-model="checktime" value="6" name="time" @change="gethistory"/>六个月</label>
                    <label><input type="radio"  v-model="checktime" value="12" name="time" @change="gethistory"/>一年</label>
                    <label><input type="radio"  v-model="checktime" value="36" name="time" @change="gethistory"/>三年</label>
                  </div>


                  <div class="reading_r_c_r_bottom_container">
                    <div class="reading_bot_box" v-for="type in resultList ">
                      <p><img src="../../../static/img/reportview/bg_imgsearch_11.png">状态：{{type.checkstatus}}</p>
                      <p><img src="../../../static/img/reportview/bg_imgSearch2_13.png">检查日期：{{type.repTimeStr}}</p>
                      <div class="reading_bot_box_btn">
                        <button class="button btn_blur reading_sech_view" @click="gethistorydetail(type)">查看</button>
                        <button class="button btn_blur" @click="addpacs(type)">追加影像</button>
                      </div>
                    </div>
                    <!--<div class="reading_bot_box">-->
                      <!--<p><img src="./bg_imgsearch_11.png">状态：已打印</p>-->
                      <!--<p><img src="./bg_imgSearch2_13.png">检查日期：2016/06/16</p>-->
                      <!--<div class="reading_bot_box_btn">-->
                        <!--<button class="button btn_blur reading_sech_view">查看</button>-->
                        <!--<button class="button btn_blur">追加查看</button>-->
                      <!--</div>-->
                    <!--</div>-->
                  </div>
                </div>
              </div>

              <!--查看按钮的模态-->
              <div class="reading_view_modalModal"></div>
              <div class="reading_view_modal">
                <div class="reading_view_modal_head">历史报告详细信息<span class="reading_view_modal_close">X</span></div>
                <div>
                  <table class="reading_view_modal_search">
                    <tr>
                      <td>姓名</td>
                      <td><input v-model="name" type="text" :disabled="status==20||status==25||status==30"/></td>
                      <td>报告性质</td>
                      <td>
                        <select v-model="positive" disabled style="width: 100%">
                        <option value=""></option>
                        <option value=1>阳性</option>
                        <option value=0>阴性</option>
                      </select>

                      </td>
                    </tr>
                    <tr>
                      <td>档案号</td>
                      <td><input type="text" v-model="pid" :disabled="status==20||status==25||status==30"/></td>
                      <td>危急值</td>
                      <td><input type="text" v-model="emerg" :disabled="status==20||status==25||status==30"/></td>
                    </tr>
                  </table>
                </div>
                <div class="reading_view_modal_check">
                  <div class="">
                    <div class="reading_view_modal_checkHead" >检查描述</div>
                    <div>
                      <textarea v-model="description1" :disabled="status==20||status==25||status==30"></textarea>
                    </div>
                  </div>
                  <div>
                    <div class="reading_view_modal_checkHead" >检查结论</div>
                    <div>
                      <textarea v-model="result1" :disabled="status==20||status==25||status==30"></textarea>
                    </div>
                  </div>
                </div>
                <div class="reading_view_modal_footBtn">
                  <button class="button btn_blur btn_max"  @click="addhistory"  :class="(status==20||status==25||status==30)?'btn_333':'btn_blur'" :disabled="status==20||status==25||status==30" >追加</button>
                  <button class="button btn_blur btn_max"  @click="replacehistory()" :class="(status==20||status==25||status==30)?'btn_333':'btn_blur'" :disabled="status==20||status==25||status==30">替换</button>
                </div>
              </div>

            </div>
            <div class="reading_right_footBtn">
              <button class="button " :class="(status==20||status==25||status==30)?'btn_333':'btn_blur'"  :disabled="status==20||status==25||status==30"  @click="savePatResult()" v-if="checkButton('view_save')">保存结论<img src="../../../static/img/reportview/jielun_16.png"/></button>

              <button class="button btn_green" :class="(status==''||status==1||status==5||status==10||status==20||status==25||status==30)?'btn_333':'btn_blur'"  :disabled="status==''||status==1||status==5||status==10||status==20||status==25||status==30" @click="audit()" v-if="checkButton('view_audit')">审核<img src="../../../static/img/reportview/shenhe_16.png"/></button>
              <button class="button btn_yellow" :class="(status==''||status==1||status==5||status==10||status==15)?'btn_333':'btn_blur'"  :disabled="status==''||status==1||status==5||status==10||status==15" @click="repeal()" v-if="checkButton('view_cancel')">撤销审核<img src="../../../static/img/reportview/delete.png"/></button>
              <button class="button btn_the_green" :class="(status==''||status==1||status==5||status==10||status==15||status==25||status==30)?'btn_333':'btn_blur'"  :disabled="status==''||status==1||status==5||status==10||status==15||status==25||status==30" @click="printview()" v-if="checkButton('view_preview')">打印预览<img src="../../../static/img/reportview/yulan_22.png"/></button>
              <button class="button bg_deepBlue" :class="(status==''||status==1||status==5||status==10||status==15||status==25||status==30)?'btn_333':'btn_blur'"  :disabled="status==''||status==1||status==5||status==10||status==15||status==25||status==30" @click="print" v-if="checkButton('view_print')">打印<img src="../../../static/img/reportview/dayin_16.png"/></button>
            </div>
          </div>

          <!--补充登记信息-->
          <div class="reading_supReg">
            <!--一层-->
            <table class="reading_supReg_tableList">
              <tr>
                <td>姓名</td>
                <td><input type="text"/></td>
                <td>性别</td>
                <td>
                  <select>
                    <option>男</option>
                    <option>女</option>
                  </select>
                </td>
                <td>年龄</td>
                <td>
                  <input type="text" class="reading_ageInput">
                  <select class="reading_ageSelect">
                    <option>岁</option>
                    <option>月</option>
                    <option>日</option>
                  </select>
                </td>
              </tr>
              <tr>
                <td>别名</td>
                <td><input type="text"></td>
                <td>联系电话</td>
                <td><input type="text"></td>
                <td>身份证号</td>
                <td><input type="text"></td>
              </tr>
              <tr>
                <td>开单时间</td>
                <td><input type="text"/></td>
                <td>开单科室</td>
                <td>
                  <select>
                    <option></option>
                  </select>
                </td>
                <td>开单医生</td>
                <td>
                  <select>
                    <option></option>
                  </select>
                </td>
              </tr>
              <tr>
                <td>病区</td>
                <td><input type="text"/></td>
                <td>床号</td>
                <td><input type="text"/></td>
                <td>门诊号</td>
                <td><input type="text"/></td>
              </tr>
              <tr>
                <td>住院日期</td>
                <td><input type="date"/></td>
                <td>住院次数</td>
                <td><input type="text"/></td>
                <td>住院号</td>
                <td><input type="text"/></td>
              </tr>
              <tr>
                <td>申请单</td>
                <td><input type="text"/></td>
                <td>紧急程度</td>
                <td><input type="text"/></td>
                <td></td>
                <td></td>
              </tr>
            </table>
            <!--二层-->
            <table class="reading_supReg_tableList reading_supReg_tableList2">
              <tr>
                <td>设备类型</td>
                <td>
                  <select>
                    <option></option>
                  </select>
                </td>
                <td>设备名称</td>
                <td>
                  <select>
                    <option></option>
                  </select>
                </td>
                <td>影像号</td>
                <td><input type="text"/></td>
              </tr>
              <tr>
                <td>登记时间</td>
                <td><input type="date"/></td>
                <td>预约日期</td>
                <td><input type="date"></td>
                <td>患者类型</td>
                <td>
                  <select>
                    <option></option>
                  </select>
                </td>
              </tr>
            </table>
            <!--三层-->
            <table class="reading_supReg_third">
              <tr>
                <td>医嘱信息</td>
                <td><input type="text"></td>
                <td>临床诊断</td>
                <td><input type="text"></td>
              </tr>
              <tr>
                <td>提示信息</td>
                <td colspan="3"><textarea></textarea></td>
              </tr>
            </table>

            <!--四层-->
            <ul class="reg_r_t_list line_height_20 clear">
              <li>收费项目</li>
              <li>
                <ul class="scroll2">
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                </ul>
              </li>
              <li>部位</li>
              <li>
                <ul class="scroll2">
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                  <li>XXX部位</li>
                </ul>
              </li>
            </ul>

            <div class="reg_right_btn">

              <button class="button bg_blur color_white" id="projectSite">更改收费项目和部位</button>

              <div class="reg_r_btn_modal"></div>
              <div class="reg_r_btn_modal_cont">

                <div class="reg_modal_head line_height_40">
                  <div>收费项目</div>
                  <div>部位</div>
                </div>
                <div class="reg_table_modalBox">
                  <div class="reg_table_modalBox_left">
                    <!--<p>外部收费项目</p>-->
                    <ul class="tree_down">
                      <li>
                        <a>一级菜单</a>
                        <ul>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                        </ul>
                      </li>
                      <li>
                        <a>一级菜单</a>
                        <ul>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                        </ul>
                      </li>
                    </ul>
                    <div class="reg_table_modalBox_foot">
                      <input type="text"/>
                      <div class="clear">
                        <button>XXXXX<span>X</span></button>
                        <button>XX发的发生的XXX<span>X</span></button>
                        <button>XXX但是风格的风格XX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                      </div>
                    </div>
                  </div>
                  <div class="reg_table_modalBox_right">
                    <!--<p>外部部位</p>-->
                    <ul class="tree_down">
                      <li>
                        <a>一级菜单</a>
                        <ul>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                        </ul>
                      </li>

                      <li>
                        <a>一级菜单</a>
                        <ul>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                          <li><a>二级菜单</a></li>
                        </ul>
                      </li>
                    </ul>

                    <div class="reg_table_modalBox_foot">
                      <input type="text"/>
                      <div class="clear">
                        <button>XXXXX<span>X</span></button>
                        <button>XX发的发生的XXX<span>X</span></button>
                        <button>XXX但是风格的风格XX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XX发的发生的XXX<span>X</span></button>
                        <button>XXX但是风格的风格XX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                        <button>XXXXX<span>X</span></button>
                      </div>
                    </div>
                  </div>
                </div>

                <div class="reg_r_btn_modal_c_fontBtn">
                  <button class="button btn_yellow color_white" id="projectSiteCancel">取消&nbsp;&nbsp;&nbsp;X</button>
                  <button class="button btn_green color_white">确定&nbsp;&nbsp;&nbsp;√</button>
                </div>
              </div>
            </div>

            <div class="reading_right_footBtn1">
              <!--<button class="button btn_yellow">删除<img src="img/delete.png"/></button>

              -->
              <!--<button class="button btn_green">新增<img src="img/zengjia.png"/></button>-->
              <button class="button btn_blur">保存<img src="../../../static/img/reportview/jielun_16.png"/></button>
              <!--<button class="button btn_the_green">阅片<img src="img/yuepian.png"/></button>-->
            </div>

          </div>

          <!--报告流程-->
          <div class="report_process">
            <div class="report_process_search">
              <table class="">
                <tr>
                  <td>查询时间</td>
                  <td><input type="date" v-model="timebegin" class="aaa"/></td>
                  <td><div>至</div></td>
                  <td><input type="date" v-model="timeend"/></td>
                  <td>操作者</td>
                  <td>
                    <select v-model="loguser">
                      <option></option>
                      <option v-for="type in logUserList" :value="type.name">{{type.name}}</option>
                    </select>
                  </td>
                </tr>
                <tr>
                  <td>选择类型</td>
                  <td>
                    <select v-model="loglevel">
                      <option></option>
                      <option>Info</option>
                      <option>Debug</option>
                      <option>Warn</option>
                      <option>Error</option>
                    </select>
                  </td>
                  <td>内容</td>
                  <td><input type="text" v-model="message"/></td>
                  <td></td>
                  <td><button class="button btn_yellow" @click="getConditionLog()">查询</button></td>
                </tr>
              </table>
            </div>
            <div class="report_process_list line_height_30">
              <table>
                <tr>
                  <td>类型</td>
                  <td>操作者</td>
                  <td>内容</td>
                  <td>日期</td>
                </tr>
              </table>
              <div class="report_process_list_cont">
                <table>
                  <tr v-for="(log,index) in logList">
                    <td v-model="loglevel1">{{log.loglevel}}</td>
                    <td v-model="logname1">{{log.name}}</td>
                    <td v-model="message1">{{log.message}}</td>
                    <td v-model="logdateStr1">{{log.logdateStr}}</td>
                  </tr>
                </table>
              </div>
            </div>
          </div>
        </div>
      </div>

      <!--<div class="ris_footer pg_foot">&copy;Copyright&nbsp;2017&nbsp;&nbsp;北京金风易通科技医疗有限公司&nbsp;&nbsp;版权所有</div>-->
    </div>
  <!--</div>-->
  </div>
</template>



<script>
  import Header from '@/components/Header/Header';
  import { Message, MessageBox,Notification } from 'element-ui'
  import {getButtonPermission} from '@/api/user';


  export default {
    components: {
      'v-header': Header
    },
    created () {

      var format = "";
      var nTime = new Date();
      format += nTime.getFullYear()+"-";
      format += (nTime.getMonth()+1)<10?"0"+(nTime.getMonth()+1):(nTime.getMonth()+1);
      format += "-";
      format += nTime.getDate()<10?"0"+(nTime.getDate()):(nTime.getDate());
//      format += "T";
////      format += nTime.getHours()<10?"0"+(nTime.getHours()):(nTime.getHours());
//      format += "00";
//      format += ":";
//      format += "00";
//      format += nTime.getMinutes()<10?"0"+(nTime.getMinutes()):(nTime.getMinutes());
//      format += ":00";
      var formathour = "";
      var Time = new Date();
//      formathour=Time.getHours()<10?"0"+(Time.getHours()):(Time.getHours());
      formathour += "00";
      formathour += ":";
      formathour += "00";
//      formathour += Time.getMinutes()<10?"0"+(Time.getMinutes()):(Time.getMinutes());
//      console.log(formathour);
      formathour += ":00";
      var formathourend="";

      formathourend+= Time.getHours()<10?"0"+(Time.getHours()):(Time.getHours());
      formathourend += ":";
      formathourend+= Time.getMinutes()<10?"0"+(Time.getMinutes()):(Time.getMinutes());
      formathourend += ":00";

//      var formatdate='';
//      var date = new Date();
//      formatdate += date.getFullYear()+"-";
//      formatdate += (date.getMonth()+1)<10?"0"+(date.getMonth()+1):(date.getMonth()+1);
//      formatdate += "-";
//      formatdate += date.getDate()<10?"0"+(date.getDate()):(date.getDate());
//      formatdate += "T";
//      formatdate += date.getHours()<10?"0"+(date.getHours()):(date.getHours());
////      formatdate += "00";
//      formatdate += ":";
////      formatdate += "00";
//      formatdate += nTime.getMinutes()<10?"0"+(nTime.getMinutes()):(nTime.getMinutes());
//      formatdate += ":00";

      //2017-12-12T05:15
//      console.log(format+"____2017-12-12T05:15")

//      var format1=substr(format.length-2,format.length);
//      console.log(format1)
      this.begintime=format;
      this.endtime=format;
      this.beginhour=formathour;
      this.endhour=formathourend;
      console.log(this.begintime+' '+this.beginhour);
      console.log(this.endtime+' '+this.endhour);

      getButtonPermission(this.buttonPermission).then(response => {
        this.buttons = response.data;
      })
      this.$http.get(window.localStorage.url+"/log/getLogUserList")
        .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.logUserList=res.data.data;
          }
        });

      this.$http.get(window.localStorage.url+"/base/getDeptEqpEqptypeByActor")
        .then(function (res) {
//          console.log(res.data.eqptypeList);
          if(res.data.status=='SUCCESS'){
            this.eqptypeList=res.data.eqptypeList;
          }
        });
      this.$http.get(window.localStorage.url+"/base/getDeptEqpEqptypeByActor")
        .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.equipList=res.data.equipList;
          }
        });

      this.$http.get(window.localStorage.url+"/user/getList")
        .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.userList=res.data.data;
          }
        });
            this.$http.get(window.localStorage.url+"/pat/getReportList?name="+this.name+"&pid="+this.pid+"&parts="+this.parts+"&eqpType="+this.eqpType+"&eqpName="+this.eqpName+"&beginnum="+this.beginnum+"&endnum="+this.endnum+"&begintime="+(this.begintime+' '+this.beginhour)+"&endtime="+(this.endtime+' '+this.endhour))
        .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.patInfoList=res.data.data;
          }
        });
      this.$http.get(window.localStorage.url+"/template/getList?infoid=" )
        .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.baseTemplateList=res.data.data;
          }
        });
    },
    data () {
      return {
        searchRepUser:'',
        searchAutiUser:'',
        showRepUser:false,
        showAutiUser:false,
        baseTemplateList:[],//模板列表
        eqptypeList:[],//设备类型列表
        equipList:[],//设备列表
        partList:[],//部位列表
        result:"",//检查结果
        description:"",//描述
        addOrReplace:"replace",//默认替换
        emerg:"",//危急情况
        positive:"",//阴阳性
        patInfoList:[],//左侧人员列表
        id:"",//人员id
        name:"",//姓名
        pid:"",//人员pid
        parts:"",
        eqpName:"",
        beginnum:"",
        endnum:"",
        begintime:"",
        beginhour:'',
        //this.formatday()
        endtime:"",
        endhour:"",
        eqpType:"",
        userList:"",
//        patResult:"",
        advice:"",
        audituserCode:"",
        auditTime:"",
        printTime:"",
        printuserCode:"",
        repTime:"",
        repuserCode:"",
        infoId:"",
        resultid:"",//pat_result id
        status:"",//状态
        patpid:"",//人员唯一门诊号
        recordno:"",//档案号用于查询历史记录
        areacode:"",//区域号
        checktime:"3",//历史报告查询时间

        resultList:[],//历史列表

        historyresult:"",//历史结果
//        historyid:"",
//        firUl:true,//一级显示隐藏
//        togglenextToggle:true,//二级显示隐藏
        description1:"",//追加历史
        result1:"",//历史结论
        stuuid:"",
        patinfo:{
        },
        patPacs:'',
        typePat:'',
        loading: false,
        buttonPermission: 'view',
        message:'',
        timebegin:'',
        timeend:'',
        loguser:'',
        loglevel:'',
        loglevel1:'',
        logname1:'',
        message1:'',
        logdateStr1:'',
        logUserList:[],
        logList:[],
        logdateStr:'',
        thisColor:'red'
      }
    },
    methods: {

      //点击加载部位
      getpartList:function () {
//        console.log(this.infoId)
//        console.log(this.eqpType);
        this.$http.get(window.localStorage.url+"/base/getPart?eqpType="+this.eqpType)
          .then(function (res) {
//              console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.partList=res.data.data;
            }
          });
      },

      checkButton(code) {
        for(var i in this.buttons){
          if (code == this.buttons[i]) {
            return true;
          }
        }
        return false;
      },



  //三个table切换
      table_pageTitle:function(num){
        $(event.currentTarget).addClass('reading_table_page_active').siblings('.reading_table_page_active').removeClass('reading_table_page_active');
        if(num==0){
          $('.writeReport').show().siblings().hide();
        }else if(num==1){
          $('.reading_supReg').show().siblings().hide();
        }else {
          //报告流程
          $('.report_process').show().siblings().hide();
//          console.log(this.infoId);
//          console.log(this.patpid);
          this.$http.get(window.localStorage.url+"/log/getLogDetail?infoid="+this.infoId+"&pid="+this.patpid+"&timebegin="+this.timebegin+"&timeend="+this.timeend+"&loguser="+this.loguser+"&logtype="+this.loglevel+"&message="+this.message)
            .then(function (res) {
//              console.log(res.data);
              if(res.data.status=='SUCCESS'){
                console.log(res.data);
                this.logList=res.data.data;
                this.loglevel1=res.data.data.loglevel==undefined?"":res.data.data.loglevel ;
                this.logname1=res.data.data.name==undefined?"":res.data.data.name ;
                this.message1=res.data.data.message==undefined?"":res.data.data.message ;
                this.logdateStr1=res.data.data.logdateStr==undefined?"":res.data.data.logdateStr ;

              }
            });

        }
      },
      getConditionLog:function () {

        this.$http.get(window.localStorage.url+"/log/getLogDetail?infoid="+this.infoId+"&pid="+this.patpid+"&timebegin="+this.timebegin+"&timeend="+this.timeend+"&loguser="+this.loguser+"&logtype="+this.loglevel+"&message="+this.message)
          .then(function (res) {
//              console.log(res.data);
//            console.log(res.data.status)
            if(res.data.status=='SUCCESS'){
              console.log(res.data);
              this.logList=res.data.data;
              this.loglevel1=res.data.data.loglevel==undefined?"":res.data.data.loglevel ;
              this.logname1=res.data.data.name==undefined?"":res.data.data.name ;
              this.message1=res.data.data.message==undefined?"":res.data.data.message ;
              this.logdateStr1=res.data.data.logdateStr==undefined?"":res.data.data.logdateStr ;

            }
          });
      },
      toggle:function(event){
//        console.log($($(event).get(0).target).siblings("ul"));
//        console.log(event)
        var _this=$(event).get(0).target
        $($(event).get(0).target).siblings("ul").toggle();

        if($(_this).siblings('ul').is(':hidden')){
          $(_this).children('img').css({
            transform:'rotate(0deg)'
          })
        }else {
          $(_this).children('img').css({
            transform:'rotate(-90deg)'
          })
        }


      },

//历史列表

      gethistory:function () {
       // console.log(this.recordno);
        //console.log(this.patpid);
//        console.log(this.checktime)
//        console.log(this.infoId)
        if(this.patpid!=null&&this.patpid!=''){
          this.$http.get(window.localStorage.url+"/pat/getHistoryList/"+this.recordno+"/"+this.checktime+"/"+this.infoId)
            .then(function (res) {
//              console.log(res.data);
              if(res.data.status=='SUCCESS'){
                this.resultList=res.data.data;
              }
            });
        }


      },
      //追加查看pacs
      addpacs(type){
//        console.log(type.id)
//        console.log(type.patpid);
//        console.log(this.stuuid);
        var pid=this.typePat.pid;
        var infoid =this.typePat.id;

//        console.log(pid);
//        console.log(infoid);

        this.$http.get(window.localStorage.url+"/pat/getStuuid/"+pid+'/'+infoid)
          .then(function (res) {
//            console.log(pid);
//            console.log(infoid);
//            console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.stuuid=res.data.data;
//              console.log(res.data.data)
//              window.open("http://demo.dayisheng.com/wpacs.aspx?stuuid="+res.data.data+"&user=cc&pswd=dd","newwindow","height=800, width=1366, toolbar=no, menubar=no, scrollbars=no, resizable=no, location=no, status=no, left=100px, top=100px")

              this.$http.get(window.localStorage.url+"/pat/getStuuid/"+type.patpid+'/'+type.id)
                .then(function (res) {
//                  console.log(type.pid);
//                  console.log(type.id);
//                  console.log(res.data);
                  if(res.data.status=='SUCCESS'){
                    this.patPacs=res.data.data;
//              console.log(res.data.data.stuuid);
                    //console.log(this.stuuid);

                      window.open( window.localStorage.pacsUrl+"?stuuid="+this.stuuid+","+res.data.data+"&user=cc&pswd=dd","newwindow","height=800, width=1366, toolbar=no, menubar=no, scrollbars=no, resizable=no, location=no, status=no, left=100px, top=100px")

//              console.log(res.data.data.stuuid);

                  }
                });


            }
          });






      },
      //检查部位
      getpartsByType(type){
        this.$http.get(window.localStorage.url+"/base/getPart?eqpType="+type)
          .then(function (res) {
//              console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.partList=res.data.data;
            }
          });
      },


      //详细历史信息
      gethistorydetail(type){
//        console.log(type.id)
//        console.log(type.patpid)
 //       console.log(this.infoId);

        this.$http.get(window.localStorage.url+"/pat/getHistoryDetail/"+type.patpid+"/"+type.id)
          .then(function (res) {
 //           console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.historyresult=res.data.data;
              this.age=res.data.data.age==undefined?"":res.data.data.age;
              this.name=res.data.data.cname==undefined?"":res.data.data.cname;
              this.description1=res.data.data.description==undefined?"":res.data.data.description;
              this.eqpTypeName=res.data.data.eqpTypeName==undefined?"":res.data.data.eqpTypeName;
              this.positive=res.data.data.positive==undefined?"":res.data.data.positive;
              this.emerg=res.data.data.emerg==undefined?"":res.data.data.emerg;
//              this.sex=res.data.data.sex==undefined?"":res.data.data.sex;
              this.pid=res.data.data.patpid==undefined?"":res.data.data.patpid ;
//              this.reptime=res.data.data.reptime==undefined?"":res.data.data.reptime;
              this.result1=res.data.data.result==undefined?"":res.data.data.result;
            }
          });
      },
//追加替换
      addorreplace:function(index1,index2,index3){
        if(this.status==20||this.status==25||this.status==30){
          return false;
        }
          $($(event).get(0).target).parents('.tree_down').find('.color_red').removeClass('color_red');
          $($(event).get(0).target).addClass('color_red');

//          console.log(index1);
//          console.log(index2);
//          console.log(index3);
//          console.log(this.baseTemplateList[index1].partList[index2].templateList[index3].description);
        var text1=this.baseTemplateList[index1].partList[index2].templateList[index3].description;
//          console.log(this.baseTemplateList[index1].partList[index2].templateList[index3].result);
        var text2=this.baseTemplateList[index1].partList[index2].templateList[index3].result;
        var text3=this.baseTemplateList[index1].partList[index2].templateList[index3].advice;

        if(this.addOrReplace=="replace"){

          this.description=text1;
          this.result=text2;
          this.advice=text3;
        }
        else if(this.addOrReplace=="add"){

          this.description+=text1;
          this.result+=text2;
          this.advice+=text3;
        }
        var pos=this.baseTemplateList[index1].partList[index2].templateList[index3].positive;
//        console.log(pos);
        if(pos==1){
          this.positive=1;
        }
        else if(pos==0){
          this.positive=0;
        }
        else {
          this.positive="";
        }
        var emergs=this.baseTemplateList[index1].partList[index2].templateList[index3].emerg;
//        console.log(emergs);
        if(emergs=="危急"){
          this.emerg="危急";
        }
        else if(emergs=="不危急"){
          this.emerg="不危急";
        }
        else {
          this.emerg="";
        }


      },
      //详细结果信息
      getResultDetail:function (pat) {
        this.typePat=pat;
        this.patinfo=pat;
        var id=pat.id;
        var pid=pat.pid;
//        console.log(id)
//        console.log(pid);
        var checktime=this.checktime;
//        console.log(stuuid)
//        console.log(id);
//        console.log(pid);
//        console.log(checktime);

//        console.log(id)
        this.$http.get(window.localStorage.url+"/pat/getResultById/"+id)
          .then(function (res) {
 //           console.log(res.data)
            if(res.data.status=="SUCCESS"){
//              this.patResult=res.data.data;
              this.description=res.data.data.description==undefined?"":res.data.data.description;
              this.result=res.data.data.result==undefined?"":res.data.data.result;
              this.emerg=res.data.data.emerg==undefined?"":res.data.data.emerg;
              this.positive=res.data.data.positive==undefined?"":res.data.data.positive;
              this.advice=res.data.data.advice==undefined?"":res.data.data.advice;
              this.repTime=res.data.data.repTimeStr==undefined?"":res.data.data.repTimeStr;
              this.auditTime=res.data.data.audittimeStr==undefined?"":res.data.data.audittimeStr;
              this.repuserCode=res.data.data.repusercode==undefined?"":res.data.data.repusercode;
              this.searchRepUser=this.getUserName(this.repuserCode);
              this.audituserCode=res.data.data.auditusercode==undefined?"":res.data.data.auditusercode;
              this.searchAutiUser=this.getUserName(this.audituserCode);
              this.infoId=id;
              this.patpid=pid;
              this.recordno=res.data.data.recordno==undefined?"":res.data.data.recordno;
              this.areacode=res.data.data.areacode==undefined?"":res.data.data.areacode;
              this.resultid=res.data.data.id==undefined?"":res.data.data.id;
              this.status=res.data.data.status==undefined?"":res.data.data.status;
//              console.log(res.data.data.status)
//              this.stuuid=stuuid;
//              console.log(this.status);
//              this.gethistory();

            }
            this.getConditionLog();
          });
        this.$http.get(window.localStorage.url+"/pat/getHistoryList/"+pid+'/'+checktime+'/'+id)
           .then(function (res) {
//          console.log(res.data);
          if(res.data.status=='SUCCESS'){
            this.resultList=res.data.data;
          }
        });
        this.$http.get(window.localStorage.url+"/template/getList?infoid="+id)
          .then(function (res) {
//          console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.baseTemplateList=res.data.data;
            }
          });
      },
      //查看影像
      imagesearch:function (item) {

//        console.log(item.pid);
        var pid=item.pid;
        var infoid =item.id;
        this.$http.get(window.localStorage.url+"/pat/getStuuid/"+pid+'/'+infoid)
          .then(function (res) {
//         console.log(res.data);
            if(res.data.status=='SUCCESS') {
              this.stuuid = res.data.data;
              console.log(res.data.data)
              if (null != res.data.data&& res.data.data!=''&&res.data.data!=undefined) {
                window.open(window.localStorage.pacsUrl + "?stuuid=" + res.data.data + "&user="+window.localStorage.pacsUsername+"&pswd="+window.localStorage.pacsPassword,"newwindow", "height=800, width=1366, toolbar=no, menubar=no, scrollbars=no, resizable=no, location=no, status=no, left=100px, top=100px")
              }
            }
          });

//        window.open("http://demo.dayisheng.com/wpacs.aspx?stuuid="+item.stuuid+"&user=cc&pswd=dd","newwindow","height=800, width=1366, toolbar=no, menubar=no, scrollbars=no, resizable=no, location=no, status=no, left=100px, top=100px")
//        this.stuuid=item.stuuid;

      },
      //保存检查报告结论
      savePatResult:function () {
        var $this = this;
        $this.$http.post(window.localStorage.url + "/pat/savePatResult", {
          description: $this.description,
          result: $this.result,
          emerg: $this.emerg,
          positive: $this.positive,
          advice: $this.advice,
          reptime: $this.repTime,
          audittime: $this.auditTime,
          repusercode: $this.repuserCode,
          auditusercode: $this.audituserCode,
          infoid: $this.infoId,
          id: $this.resultid,
          areacode: $this.areacode,
        })
          .then(function (res) {
//                console.log(res.data)
            if (res.data.status == "SUCCESS") {
              this.$notify({
                title: '成功',
                type: 'success',
                message: res.data.message,
                duration: 3000,
                offset: 35
              });
            }
            this.info();
//               this.$http.get(window.localStorage.url+"/pat/getResultById/"+id)
          });
      },
//审核
      audit:function () {
        var $this = this;
//      var infoid=this.infoId;
//      console.log(infoid);
        $this.$http.post(window.localStorage.url+"/pat/audit",{
            description: $this.description,
            result: $this.result,
            emerg: $this.emerg,
            positive: $this.positive,
            advice: $this.advice,
            reptime: $this.repTime,
            audittime: $this.auditTime,
            repusercode: $this.repuserCode,
            auditusercode: $this.audituserCode,
            infoid: $this.infoId,
            id: $this.resultid,
            areacode: $this.areacode,
          })
          .then(function (res) {
//            console.log(res.data)
            if(res.data.status=="SUCCESS"){
              /*Message({
                message: res.data.message,
                type: 'success',
                duration: 2 * 1000
              })*/
              this.$notify({
                title: '成功',
                type: 'success',
                message: res.data.message,
                duration: 3000,
                offset: 35
              });
//               this.$http.get(window.localStorage.url+"/pat/getResultById/"+id)
            }
            this.info();
          });

      },
      //撤销审核
      repeal:function () {
        var $this=this;
        this.$confirm('是否确定撤销?', '提示', {
          confirmButtonText: '确定',
          cancelButtonText: '取消',
          type: 'warning'
        }).then(() => {
          $this.$http.post(window.localStorage.url+"/pat/repeal",{
            description: $this.description,
            result: $this.result,
            emerg: $this.emerg,
            positive: $this.positive,
            advice: $this.advice,
            reptime: $this.repTime,
            audittime: $this.auditTime,
            repusercode: $this.repuserCode,
            auditusercode: $this.audituserCode,
            infoid: $this.infoId,
            id: $this.resultid,
            areacode: $this.areacode,
          })
            .then(function (res) {
//                console.log(res.data)
              if(res.data.status=="SUCCESS"){
                /*this.$message({
                  type: 'success',
                  message:res.data.message,
                });*/
                this.$notify({
                  title: '成功',
                  type: 'success',
                  message: res.data.message,
                  duration: 3000,
                  offset: 35
                });

              }
              else{
                /*this.$message({
                  type: 'error',
                  message:res.data.message,
                });*/
                this.$notify.error({
                  title: '失败',
                  type: 'error',
                  message: res.data.message,
                  duration: 3000,
                  offset: 35
                });
              }
              this.info();
            });
        }).catch(() => {
          /*this.$message({
            type: 'info',
            message: '已取消撤销'
          });*/
          this.$notify.info({
            title: '取消',
            message: '已取消撤销',
            duration: 3000,
            offset: 35
          });
        });
//            var infoid=$this.infoId;
//            $this.$http.post(window.localStorage.url+"/pat/repeal/"+$this.infoId)
//              .then(function (res) {
////                console.log(res.data)
//                if(res.data.status=="SUCCESS"){
//
//                  this.info();
//                }
//              });
//
      },
      //刷新数据回查详细结果的方法
      info:function () {

        var infoid=this.infoId;
        this.$http.get(window.localStorage.url+"/pat/getResultById/"+infoid)
          .then(function (res) {
//            console.log(res.data)
            if(res.data.status=="SUCCESS"){
//              this.patResult=res.data.data;
              this.description=res.data.data.description==undefined?"":res.data.data.description;
              this.result=res.data.data.result==undefined?"":res.data.data.result;
              this.emerg=res.data.data.emerg==undefined?"":res.data.data.emerg;
              this.positive=res.data.data.positive==undefined?"":res.data.data.positive;
              this.advice=res.data.data.advice==undefined?"":res.data.data.advice;
              this.repTime=res.data.data.repTimeStr==undefined?"":res.data.data.repTimeStr;
              this.auditTime=res.data.data.audittimeStr==undefined?"":res.data.data.audittimeStr;
              this.repuserCode=res.data.data.repusercode==undefined?"":res.data.data.repusercode;
              this.searchRepUser=this.getUserName(res.data.data.repusercode==undefined?"":res.data.data.repusercode);
              this.audituserCode=res.data.data.auditusercode==undefined?"":res.data.data.auditusercode;
              this.searchAutiUser=this.getUserName(res.data.data.auditusercode==undefined?"":res.data.data.auditusercode);
//                   this.infoId=id;
//                   this.patpid=pid;
              this.areacode=res.data.data.areacode==undefined?"":res.data.data.areacode;
              this.resultid=res.data.data.id==undefined?"":res.data.data.id;
              this.status=res.data.data.status==undefined?"":res.data.data.status;
//              this.stuuid=stuuid;
//              console.log(this.status);
//              this.gethistory();

            }
          });
      },
      //打印预览
      printview:function () {
//        console.log(this.areacode+this.patpid);
        console.log(this.infoId);
        console.log(this.patpid);
        this.$http.get(window.localStorage.url+"/print/rptAll?pids="+this.infoId+"&rptName="+"检查报告"+"&areacode="+"1"+"&actionName="+"preview")
          .then(function (res) {
            console.log(res.data);
            if(res.data.status=='SUCCESS') {


            }
          });
//        var data1={"Action":"BarCodePrint","TestNo":this.infoId,"ReportType":"检查报告","AreaCode":this.areacode,"DesignMode":""};
//        var data =encodeURIComponent(encodeURIComponent(JSON.stringify(data1)));
//        $.ajax({
//          url:'http://127.0.0.1:9105/?data='+data,
//          type:'get',
//          dataType:'jsonp',
//          success:function (data) {
////            console.log("successs");
//          }
//        })

      },
      //打印
      print:function () {
        var $this=this;
        var infoid=this.infoId;
        this.$http.get(window.localStorage.url+"/print/rptAll?pids="+this.infoId+"&rptName="+"检查报告"+"&areacode="+"1")
          .then(function (res) {
            console.log(res.data);
            if(res.data.status=='SUCCESS') {
              if(res.data.status=="SUCCESS"){
                this.$notify({
                  title: '成功',
                  type: 'success',
                  message: res.data.message,
                  duration: 3000,
                  offset: 35
                });

              }
//                    console.log(11111111111)
              $this.$http.post(window.localStorage.url+"/pat/printStatus/"+infoid)
                .then(function (res) {
//                console.log(res.data)

                  this.info();
                });
            }
          });

//        var data1={"Action":"BarCodePrint","TestNo":this.infoId,"ReportType":"检查报告","AreaCode":this.areacode}
//        var data =encodeURIComponent(encodeURIComponent(JSON.stringify(data1)));
//        $.ajax({
//          url:'http://127.0.0.1:9105/?data='+data,
//          type:'get',
//          dataType:'jsonp',
//          success:function (data) {
//            console.log("successs");
//            console.log(infoid);

//          }
//        })


      },
      //条件查询左侧列表
      getListByCondition:function () {
//        console.log(this.begintime)
        this.loading=true;
        this.$http.get(window.localStorage.url+"/pat/getReportList?name="+this.name+"&pid="+this.pid+"&parts="+this.parts+"&eqpType="+this.eqpType+"&eqpName="+this.eqpName+"&beginnum="+this.beginnum+"&endnum="+this.endnum+"&begintime="+(this.begintime+' '+this.beginhour)+"&endtime="+(this.endtime+' '+this.endhour))
          .then(function (res) {
            this.loading=false;
            console.log(res.data);
            if(res.data.status=='SUCCESS'){
              this.patInfoList=res.data.data;
            }
            else {
              this.patInfoList='';
            }
          });
      },
      //追加替换历史
      addhistory:function () {
        var description1=this.description1;
        var result1=this.result1;
        this.description=this.description+description1;
        this.result=this.result+result1;
        $('.reading_view_modal').hide()
        $('.reading_view_modalModal').hide()
      },
      replacehistory:function () {
        this.description=this.description1;
        this.result=this.result1;
        $('.reading_view_modal').hide()
        $('.reading_view_modalModal').hide()
      },
      selectRepUser(type){
        this.repuserCode=type.code;
        this.searchRepUser=type.name;
        this.showRepUser=false;
      },
      selectAutiUser(type){
        this.audituserCode=type.code;
        this.searchAutiUser=type.name;
        this.showAutiUser=false;
      },
      searchAutiUserClick(){
        console.log(2222)
        this.showAutiUser=true;
      },
      getUserName(code){
        for(var i in this.userList){
          if(this.userList[i].code==code){
            return this.userList[i].name
          }
        }
        return '';
      }
    }
    , mounted(){


      var input={
          value:$('.aaa').val(),
          init:function () {
            var _this=this;
            document.onkeydown= function (e) {
              _this.value=$('.aaa').val();
//           console.log(e.keyCode);
              //根据按键调用与之对应的方法
              switch (e.keyCode){
                case 8: moveLeft();break;
              }
            }

            function moveLeft() {
              var isFocus=$(".aaa").is(":focus");
              if(true==isFocus){
                $('.aaa').val(_this.value);
                $('.aaa').one('blur',function () {
                  $('.aaa').val(_this.value);
                  return false;
                })
              }

            }
          }
        };
        input.init();



      $('.aaa').on('input propertychange',function () {
//        if(keyCode==)
      })


      $(document).bind('click',function () {
        if($(document).closest($(event)).length==0){
          $('.tree_down').find('.color_red').removeClass('color_red');
        }
      })


      var _this=this;
      $('body').bind("click",function(e){
        var target = $(e.target);
        if(target.closest('.drop_down_Top1').length == 0){
//          _this.showAutiUser=false;
          _this.showRepUser=false;
        }
        if(target.closest('.drop_down_Top2').length == 0){
          _this.showAutiUser=false;
//          _this.showRepUser=false;
        }
      });


       $pg.inputRetrieve({
           input:'.reading_r_c_r_top_cont_search',//input的值
           ul:'.tree_down',//ul的值   或者  table:'值'
       });



      $('.table').on('mousemove','td',function () {
        $(this).parent('tr').addClass('tableMousemove').siblings('.tableMousemove').removeClass('tableMousemove');
      })
      $('.table').on('mouseout','td',function () {
        $(this).parent('tr').removeClass('tableMousemove');
      })
      $('.table').on('click','td',function () {
        $(this).parent('tr').addClass('tableActive').siblings('.tableActive').removeClass('tableActive');
      })



//查询栏的展开和关闭

      //查看按钮
      $('.reading_r_c_r_bottom_cont').on('click','.reading_sech_view',function () {
        $('.reading_view_modal').show()
        $('.reading_view_modalModal').show()
      });
      $('.reading_view_modal_close').click(function () {
        $('.reading_view_modal').hide()
        $('.reading_view_modalModal').hide()
      });
      $(document).bind("click",function(e){
        var target = $(e.target);
        if(target.closest(".reading_view_modal").length == 0&&target.closest(".reading_sech_view").length == 0){
          $('.reading_view_modal').hide()
          $('.reading_view_modalModal').hide()
        }
      });
      $('.click_zk').click(function () {
        $('.reg_search_tabToggle').toggle();
        if($('.reg_search_tabToggle').is(':hidden')){
          $(this).text("点击展开");
        }else {
          $(this).text("点击关闭");
        }
      });
      //根据浏览器的高度来设置内容区想对应的页面显示
//      var win={
//        init:function () {
//          var winHeight=$(window).height();
////            winHeight=winHeight-
//          winHeight=(winHeight-667)/1.2;
//          winHeight=winHeight<0?0:winHeight;
//          $('.reading_left_tableCont').css({
//            height:380+winHeight+'px'
//          })
//          $('.reading_right_center').css({
//            height:510+winHeight+'px'
//          })
//          $('.reading_right_center_left').find('.reading_r_c_l_top').css({
//            height:(130+winHeight/3)+'px'
//          }).children('textarea').css({
//            height:(100+winHeight/3)+'px'
//          })
//          $('.reading_right_center_left').find('.reading_r_c_l_center').css({
//            height:(130+winHeight/3)+'px'
//          }).children('textarea').css({
//            height:(100+winHeight/3)+'px'
//          })
//          $('.reading_right_center_left').find('.reading_r_c_l_bottom').css({
//            height:80+winHeight/4+'px'
//          }).children('textarea').css({
//            height:(50+winHeight/4)+'px'
//          })
//          //补充登记页面
//          $('.reg_r_t_list>li>ul').css({
//            height:80+winHeight/2+'px'
//          })
//          //报告流程
//          $('.report_process_list_cont').css({
//            height:385+winHeight+'px'
//          })
//        }
//      };
//      win.init();

      function height() {
        var winHeight = $(window).height();
//            winHeight=winHeight-
        winHeight = (winHeight - 667) / 1.2;
        winHeight = winHeight < 0 ? 0 : winHeight;
        $('.reading_left_tableCont').css({
          height: 380 + winHeight + 'px'
        })
        $('.reading_right_center').css({
          height: 510 + winHeight + 'px'
        })
        $('.reading_right_center_left').find('.reading_r_c_l_top').css({
          height: (130 + winHeight / 3) + 'px'
        }).children('textarea').css({
          height: (100 + winHeight / 3) + 'px'
        })
        $('.reading_right_center_left').find('.reading_r_c_l_center').css({
          height: (130 + winHeight / 3) + 'px'
        }).children('textarea').css({
          height: (100 + winHeight / 3) + 'px'
        })
        $('.reading_right_center_left').find('.reading_r_c_l_bottom').css({
          height: 80 + winHeight / 4 + 'px'
        }).children('textarea').css({
          height: (50 + winHeight / 4) + 'px'
        })
        //补充登记页面
        $('.reg_r_t_list>li>ul').css({
          height: 80 + winHeight / 2 + 'px'
        })
        //报告流程
        $('.report_process_list_cont').css({
          height: 385 + winHeight + 'px'
        })
      }

     /* window.onload = function(){
        height();
      };*/

      window.onresize = function(){
        height();
      };
      height();


      //    历史报告和模板的table页切换
      $('.reading_right_click').click(function () {
        if($(this).text()=="报告模板"){
          if($('.reading_r_c_r_top_cont').height()==0){
            $('.reading_r_c_r_top_cont').animate({
              height:'385',
            },300)
            $('.reading_r_c_r_bottom_cont').animate({
              height:'0',
            },300)
          }
        }else if($(this).text()=="历史报告"){
          if($('.reading_r_c_r_bottom_cont').height()==0){
            $('.reading_r_c_r_bottom_cont').animate({
              height:'385px',
            },300)
            $('.reading_r_c_r_top_cont').animate({
              height:'0',
            },300)
          }
        }
      })
    }
  }
</script>


<style scoped>
  /*灰色按钮*/
  button.btn_333{
    background-color: #aaa !important;
    color: #fff;
    border: 0;
  }
  .tree_down_parent>ul a:hover{
    color: #635b49;
  }
  .ris_cont{
    background: #fff;
  }
  /*左边*/

  .reading_left{
    width: 30%;
    float: left;
    border: 1px solid #eee;
  }
  .reading_left_top{
    width: 100%;
    height: 36px;
    position: relative;
  }
  .reading_left_top p{
    position: absolute;
    height: 2px;
    width: 86%;
    top: 17px;
    left: 7%;
    z-index: 1;
    background: #57c8e6;
  }
  .reading_left_top span{
    display: inline-block;
    background: #fff;
    padding: 0 20px;
    line-height: 36px;
    z-index: 2;
    position: absolute;
    font-size: 16px;
    left: 38%;
    top: 0;
    font-weight: bold;
  }

  /*搜索栏*/
  .reg_search{
    width: 90%;
    margin: 10px auto 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #ddd;
  }
  .reg_search input{
    width: 100%;
  }
  .reg_search_table{
    width: 100%;
  }
  .reg_search_table tr td{
    height: 28px;
    position: relative;
  }
  .reg_search_table tr td:nth-child(1){
    width: 20%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .reg_search_table tr td:nth-child(2){width: 30%;}
  .reg_search_table tr td:nth-child(3){
    width: 20%;
    padding: 0 5px;
    text-align: justify;
    text-align-last: justify;
  }
  .reg_search_table tr td:nth-child(4){width: 30%;}
  /*.reg_search_table tr td:nth-child(5){*/
  /*width: 13.33%;*/
  /*text-align: justify;*/
  /*text-align-last: justify;*/
  /*padding: 0 5px;*/
  /*}*/
  /*.reg_search_table tr td:nth-child(6){width: 20%;}*/

  /*.reg_search_select{*/
  /*width: 30%;*/
  /*}*/
  .reg_search_table tr td input.reg_search_input{
    width: 45%;
    /*padding-right: 32px;*/
    position: relative;
    display: block;
    float: left;
  }
  .reg_search_span{
    display: block;
    float: left;
    width: 10%;
    text-align: center;
    line-height: 26px;
  }
  .reg_search_table tr td input,.reg_search_table tr td select{
    width: 100%;
    border: 1px solid #88ada6;
    color: #587770;
  }
  .reg_search_table tr td input.width_50{
    width: 50%;
    display: block;
    float: left;
  }
  .reg_search_table tr td.reading_search>button{
    float: right;
    padding: 5px 40px;
  }
  .reg_search_tabToggle{
    display: none;
  }
  .reading_left_tableHead{
    width: 100%;
    background: #b1b1b1;
  }
  .reading_left_tableCont{
    position: relative;
  }
  /*.reading_left_tableCont button{*/
    /*position: relative;*/
    /*right: 310px;*/
  /*}*/
  .reading_left_tableCont::after{

  }
  .reading_left_tableCont table{
    width: 150%;
  }
  .reading_left_list{
    position: relative;
  }
  .reading_left_tableCont_abs{
    position: absolute;
    right: 0;
    top: 33px;
  }
  .reading_left_tableCont{
    height: 330px;
    overflow: auto;
  }
  .reading_left_tableCont table tbody tr{
    position: relative;
  }
  .reading_left_tableCont_button{
    /*position: absolute;*/
    /*left: 100px;*/
    /*top: 5px;*/
  }
  .reading_left_tableCont tr th{
    background: #999;
  }
  .reading_left_tableCont tr {
    border-bottom: 1px solid #ddd;
  }

  .reading_left_tableCont tr td:nth-child(1){
    position: relative;
  }
  .reading_left_tableCont tr td{
    padding: 0 5px;
  }

  .reading_left_tableCont img{
    width: 15px;
    margin: 0 5px;
    position: relative;
    top: 3px;
  }
  .reading_left_tableCont button{
    width: 60px;
    border-radius: 5px;
    background: transparent;
    color: #00a6c8;
    height: 24px;
    border: 0;
    padding: 0;
  }
  .reading_left_tableCont table tbody tr td:nth-child(2), .reading_left_tableCont table tbody tr th:nth-child(2){
    width: 110px !important;
    text-align: left;
    box-sizing: border-box;
  }
  .reading_left_tableCont table tbody tr td:nth-child(4), .reading_left_tableCont table tbody tr th:nth-child(4){
    width: 100px;
    text-align: left;
    box-sizing: border-box;
  }
  /*.reading_left_list tr th:nth-child(1),.reading_left_list tr td:nth-child(1){width: 30%;}*/
  /*.reading_left_list tr th:nth-child(2),.reading_left_list tr td:nth-child(2){width: 15%;}*/
  /*.reading_left_list tr th:nth-child(3),.reading_left_list tr td:nth-child(3){width: 30%;}*/
  /*.reading_left_list tr th:nth-child(4),.reading_left_list tr td:nth-child(4){width: 15%;}*/
  /*.reading_left_list tr th:nth-child(5),.reading_left_list tr td:nth-child(5){width: 30%;}*/
  /*.reading_left_list tr th:nth-child(6),.reading_left_list tr td:nth-child(6){width: 15%;}*/



  /*左边点击查看医生显示的模态*/
  .reading_l_l_modal{
    position: fixed;
    left: 0;
    top: 0;
    z-index: 300;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    /*background: rgba(0,0,0,.5);*/
    display: none;
  }
  .reading_l_l_modal_cont{
    width: 300px;
    min-height: 190px;
    background: #fff;
    position: absolute;
    left: 130px;
    top: 340px;
    border: 2px solid #2b8ec7;
    border-radius: 10px;
  }
  .reading_modal_head{
    border-radius: 10px 10px 0 0;
    background: #787878;
    color: #fff;
    position: relative;
    height: 36px;
    line-height: 36px;
    text-align: center;
    font-size: 14px;
  }
  .reading_modal_head button{
    position: absolute;
    right: 0;
    top: 0;
    padding: 4px 20px;
    font-size: 18px;
    border: 0;
    background: transparent;
    color: #fff;
    cursor: pointer;
  }
  .reading_modal_contList{
    width: 90%;
    margin: 15px auto;
  }
  .reading_modal_contList>div{
    width: 20%;
    margin: 0 6.3% 20px;
    float: left;
    text-align: center;
    border: 1px solid #2699d6;
    border-radius: 5px;
    line-height: 32px;
    padding: 10px 0;
  }
  .reading_modal_contList>div>p{
    text-align: center;
  }
  .reading_modal_contList>div>p button{
    width: 80%;
    border: 0;
    padding: 3px 3%;
    border-radius: 3px;
    cursor: pointer;
    color: #fff;
  }


  /*右边*/
  .reading_right{
    width: 69%;
    float: right;
    /*border: 1px solid #fa0002;*/
    margin: 15px 0 0 0;
    position: relative;
    min-height: 575px;
  }
  .reading_right_head{
    background: #d7dbe6;
    line-height: 22px;
    font-size: 16px;
    font-weight: bold;
    box-sizing: border-box;
    padding-left: 30px;
    padding-top: 10px;
    -webkit-box-sizing: border-box;
  }
  .reading_table_page_active{
    border-bottom: 3px solid #ffa300;
  }


  /*底部按钮*/
  .reading_right_footBtn{
    position: absolute;
    right: 0;
    width: 100%;
    text-align: right;
    bottom: 0;
    height: 40px;
  }
  .reading_right_footBtn1{
    width: 100%;
    text-align: right;
    height: 40px;
  }
  .reading_right_footBtn button,.reading_right_footBtn1 button{
    width: 115px;
    height: 30px;
    border: 0;
    border-radius: 5px;
    margin: 5px 10px;
    color: #fff;
    position: relative;
  }
  .reading_right_footBtn button img,.reading_right_footBtn1 button img{
    height: 18px;
    position: absolute;
    right: 7px;
    top: 5px;
  }
  /*中间层*/
  .reading_right_center{
    width: 100%;
    height: 486px;
    /*border: 1px solid red;*/
    /*overflow: hidden;*/
    box-sizing: border-box;
  }
  /*书写报告*/
  .writeReport{
    width: 100%;
    height: 100%;
    position: relative;
    /*display: none;*/
  }
  /*补充登记信息*/
  .reading_supReg{
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    /*border: 1px solid red;*/
    display: none;
  }



  .reading_right_center_left{
    width: 70%;
    float: left;
  }
  .reading_r_c_l_top,.reading_r_c_l_center,.reading_r_c_l_bottom{
    width: 95%;
    margin: 10px auto;
    height: 80px;
    border: 1px solid #ddd;
    border-radius: 5px;
  }
  .reading_r_c_l_top>h1,.reading_r_c_l_center>h1,.reading_r_c_l_bottom>h1{
    line-height: 30px;
    padding: 0 20px;
    background: #f4f4f4;
    font-size: 14px;
    border-radius: 5px 5px 0 0;
  }
  .reading_r_c_l_top>textarea,.reading_r_c_l_center>textarea,.reading_r_c_l_bottom>textarea{
    width: 100%;
    height: 50px;
    border: 0;
    font-size: 14px;
  }
  .reading_r_c_l_footInput{
    line-height: 32px;
    width: 93%;
    margin: 0 auto;
  }
  .reading_r_c_l_footInput tr td:nth-child(1){
    width: 15%;
    padding: 0 10px;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    text-align: justify;
    text-align-last: justify;
  }
  .reading_r_c_l_footInput tr td:nth-child(2){width: 30%;}
  .reading_r_c_l_footInput tr td:nth-child(3){
    width: 15%;
  }
  .reading_r_c_l_footInput tr td:nth-child(4){width: 30%;}
  .reading_r_c_l_footInput input,.reading_r_c_l_footInput select{
    width: 90%;
  }

  /*中间右边*/
  .reading_right_center_right{
    width: 28%;
    float: right;
    /*border: 1px solid red;*/
    height: 447px;
    background: #f4f6fb;
    position: relative;
  }
  .reading_r_c_r_top,.reading_r_c_r_bottom{
    width: 100%;
    text-align: center;
    line-height: 30px;
    border-bottom: 1px solid #ddd;
    position: relative;
    cursor: pointer;
  }
  .reading_r_c_r_top>p,.reading_r_c_r_bottom>p{
    position: absolute;
    z-index: 1;
    width: 95%;
    left: 2.5%;
    top: 14px;
    height: 2px;
    background: #2b8ec6;
  }
  .reading_r_c_r_top>span,.reading_r_c_r_bottom>span{
    display: inline-block;
    padding: 0 10px;
    position: relative;
    z-index: 2;
    background: #f4f6fb;
  }
  /*报告模板*/
  .reading_r_c_r_top_cont{
    width: 90%;
    margin: 0 auto;
    position: relative;
    height: 385px;
    overflow: hidden;
  }
  .reading_r_c_r_top_cont_search{
    width: 100%;
    border: 1px solid #88ada6;
    padding: 0 30px 0 5px;
  }
  .reading_search_03{
    position: absolute;
    right: 5px;
    top: 7px;
    width: 18px;
    cursor: pointer;
  }
  .tree_down_parent{
      height: 310px;
      overflow: auto;
    }
  .tree_down_parent a{
    -moz-user-select: none;
    user-select: none;
    -webkit-user-select: none;
  }
  .tree_down_parent>ul{
    text-align: left;
  }
  .tree_down_parent>ul li{
    border: 0;
  }
  .tree_down_parent>ul a>img{
    /*position: relative;*/
    width: 8px;
    padding: 0 5px;
  }
  .tree_down_parent>ul a{
    position: relative;
    z-index: 2;
  }

  .tree_down_footCheck label{
    margin: 0 10px;
    cursor: pointer;
  }
  .tree_down_footCheck input[type=radio]{
    position: relative;
    top: 10px;
  }

  /*历史报告*/
  .reading_r_c_r_bottom_cont{
    width: 90%;
    margin: 0 auto;
    position: relative;
    height: 0;
    overflow: hidden;
  }
  .reading_r_c_r_bottom_cont_time label{
    padding: 0 5px;
  }
  .reading_r_c_r_bottom_cont_time input[type=radio]{
    position: relative;
    top: 10px;
  }
  .reading_r_c_r_bottom_container{
    width: 100%;
    height: 349px;
    overflow: auto;
    /*border: 1px solid blue;*/
    box-sizing: border-box;
    text-align: left;
  }
  .reading_bot_box{
    border: 1px solid #ddd;
    border-radius: 10px;
    margin-top: 15px;
  }
  .reading_bot_box>p{
    padding: 0 10px;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
  }
  .reading_bot_box>p:nth-child(1) img{
    position: relative;
    top: 10px;
  }
  .reading_bot_box img{
    width: 10px;
    padding: 0 5px;
  }
  .reading_bot_box_btn{
    text-align: center;
  }
  .reading_bot_box_btn button{
    padding: 2px 10px;
    border-radius: 5px;
  }


  /*查看按钮的模态*/
  .reading_view_modalModal{
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    position: fixed;
    z-index: 400;
    display: none;
  }
  .reading_view_modal{
    position: absolute;
    width: 580px;
    background: #fff;
    border: 1px solid #aaa;
    height: 500px;
    right: 100%;
    top: 18px;
    border-radius: 15px;
    z-index: 500;
    display: none;
  }
  .reading_view_modal_head{
    text-align: center;
    background: #787878;
    color: #fff;
    border-radius: 15px 15px 0 0;
    line-height: 36px;
    height: 36px;
    position: relative;
  }
  .reading_view_modal_search{
    width: 90%;
    margin: 10px auto;
  }
  .reading_view_modal_search tr td{
    height: 40px;
  }
  .reading_view_modal_search tr td:nth-child(1){
    width: 15%;
    padding: 0 5px;
    text-align: justify;
    text-align-last: justify;
  }
  .reading_view_modal_search tr td:nth-child(2){width: 35%;}
  .reading_view_modal_search tr td:nth-child(3){
    width: 15%;
    padding: 0 5px;
    text-align: justify;
    text-align-last: justify;
  }
  .reading_view_modal_search tr td:nth-child(4){width: 35%;}
  .reading_view_modal_search input{
    width: 95%;
  }
  .reading_view_modal_check{
    width: 90%;
    margin: 0 auto;
  }
  .reading_view_modal_check>div{
    border: 1px solid #ddd;
    border-radius: 10px;
    margin: 20px 0;
  }
  .reading_view_modal_checkHead{
    background: #f4f4f4;
    color: #333;
    border-radius: 10px 10px 0 0;
    line-height: 32px;
    padding-left: 20px;
    font-size: 14px;
  }
  .reading_view_modal_check textarea{
    width: 100%;
    height: 88px;
    border: 0;
  }
  .reading_view_modal_footBtn{
    text-align: center;
  }
  .reading_view_modal_footBtn button{
    margin: 0 20px;
    font-size: 14px;
  }
  .reading_view_modal_close{
    position: absolute;
    right: 0;
    top: 0;
    padding: 0 20px;
    font-size: 18px;
    cursor: pointer;
  }
  .reading_view_modal_close:hover{
    opacity: .8;
  }


  /*补充登记信息*/
  .reading_supReg_tableList{
    width: 90%;
    margin: 0 auto;
    border-bottom: 1px solid #ddd;
  }
  .reading_supReg_tableList tr td{
    height: 30px;
  }
  .reading_supReg_tableList input,.reading_supReg_tableList select{
    width: 100%;
  }
  .reading_supReg_tableList tr td:nth-child(1){
    width: 10%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .reading_supReg_tableList tr td:nth-child(2){width: 23.33%;}
  .reading_supReg_tableList tr td:nth-child(3){
    width: 10%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .reading_supReg_tableList tr td:nth-child(4){width: 23.33%;}
  .reading_supReg_tableList tr td:nth-child(5){
    width: 10%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .reading_supReg_tableList tr td:nth-child(6){width: 23.33%;}
  .reading_supReg_tableList input.reading_ageInput{
    width: 65%;
    display: block;
    float: left;
  }
  .reading_supReg_tableList select.reading_ageSelect{
    width: 35%;
    display: block;
    float: left;
  }
  .reading_supReg_tableList2 input,.reading_supReg_tableList2 select{
    border: 1px solid #88ada6;
    color: #2d3b36;
  }

  /*三层*/
  .reading_supReg_third{
    width: 90%;
    margin: 0 auto;
    line-height: 30px;
    border-bottom: 1px solid #ddd;
  }
  .reading_supReg_third input,.reading_supReg_third textarea{
    width: 100%;
    border: 1px solid #4c8dae;
    color: #284254;
  }
  .reading_supReg_third textarea{
    height: 50px;
  }
  .reading_supReg_third tr td:nth-child(1){
    width: 10%;
    padding: 0 5px;
    text-align: justify;
    text-align-last: justify;
  }
  .reading_supReg_third tr td:nth-child(2){
    width: 40%;
  }
  .reading_supReg_third tr td:nth-child(3){
    width: 10%;
    padding: 0 5px;
    text-align: justify;
    text-align-last: justify;
  }
  .reading_supReg_third tr td:nth-child(4){
    width: 40%;
  }



  /*四层*/
  .reg_r_t_list{
    width: 100%;
    padding-top: 10px;
  }
  .reg_r_t_list>li{
    float: left;
    display: inline-block;
  }
  .reg_r_t_list>li:nth-child(1){
    width: 8%;
    padding: 0 10px;
    text-align: justify;
    text-align-last: justify;
  }
  .reg_r_t_list>li:nth-child(2){width: 25%;}
  .reg_r_t_list>li:nth-child(3){
    width: 8%;
    padding: 0 15px;
    text-align: justify;
    text-align-last: justify;
  }
  .reg_r_t_list>li:nth-child(4){width: 25%;}
  .reg_r_t_list>li ul{
    width: 100%;
    border: 1px solid #4c8caf;
    border-radius: 5px;
    height: 80px;
    overflow: auto;
  }
  .reg_r_t_list>li ul li{
    padding:2px 5px ;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
  }






  /*按钮*/
  .reg_right_btn{
    width: 100%;
    text-align: right;
    padding-top: 10px;
    position: relative;
  }
  .reg_right_btn>button{
    width: 150px;
    height: 30px;
    border: 0;
  }
  .reg_r_btn_modal{
    position: fixed;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    /*background: rgba(0,0,0,.5);*/
    z-index: 3000;
    display: none;
  }
  .reg_r_btn_modal_cont{
    position: absolute;
    right: 0;
    bottom: 30px;
    /*width: 800px;*/
    /*height: 470px;*/
    background: #fff;
    z-index: 3001;
    text-align: left;
    width: 0;
    height: 0;
    overflow: hidden;
    border: 1px solid #eee;
    opacity: 0;
  }


  /*右下底部按钮*/
  /*.reg_right_footBtn{*/
  /*text-align: right;*/
  /*margin-top: 25px;*/
  /*}*/
  .reg_right_footBtn button{
    border: 0;
    margin-right: 20px;
    position: relative;
    width: 110px;
    height: 36px;
  }
  .reg_right_footBtn button p{
    display: inline-block;
  }
  .reg_right_footBtn button img{
    height: 20px;
    position: absolute;
    right: 20px;
    top: 7px;
  }
  .reg_modal_head{
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    height: 40px;
    border-radius: 10px 10px 0 0;
  }
  .reg_modal_head>div{
    float: left;
    width: 50%;
    padding-left: 20px;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    background: #727272;
    border-radius: 10px 10px 0 0;
  }
  .reg_modal_head>div:nth-child(1){
    border-right:1px solid #eee;
  }
  .reg_table_modalBox{
    width: 100%;
    height: 380px;
  }
  .reg_table_modalBox_left{
    width: 50%;
    float: left;
    border-right: 1px solid #ddd;
    height: 100%;
    box-sizing: border-box;
    border-bottom: 1px solid #ddd;
  }

  .reg_table_modalBox_left>ul,.reg_table_modalBox_right>ul{
    width: 100%;
    margin: 0 auto;
    height: 275px;
    border: 1px solid #eee;
    overflow: auto;
    box-sizing: border-box;
    line-height: 30px;
  }
  .reg_table_modalBox_left>ul>li>a,.reg_table_modalBox_right>ul>li>a{
    background: #999;
    color: #fff;
  }
  .reg_table_modalBox_left>ul>li a,.reg_table_modalBox_right>ul>li a{
    border-bottom: 1px solid #ddd;
    box-sizing: border-box;
    cursor: pointer;
  }


  .reg_table_modalBox_right{
    width: 50%;
    float: left;
    border-bottom: 1px solid #ddd;
    height: 100%;
    box-sizing: border-box;
  }

  .reg_table_modalBox_foot{
    width: 100%;
    height: 70px;
    /*border: 1px solid red;*/
  }
  .reg_table_modalBox_foot>input{
    width: 100%;
    height: 30px;
    margin: 2.5px 0;
  }
  .reg_table_modalBox_foot>div{
    width: 100%;
    height: 62px;
    overflow: auto;
    /*border: 1px solid red;*/
  }
  .reg_table_modalBox_foot>div button{
    display: inline-block;
    float: left;
    margin: 5px 3px 0;
    background: #4f90c2;
    color: #fff;
    border-radius: 5px;
    height: 26px;
    padding: 2px 10px;
    border: 0;
    position: relative;
  }
  .reg_table_modalBox_foot>div button>span{
    position: absolute;
    right: -4px;
    top: -4px;
    width: 16px;
    height: 16px;
    background: #fa5956;
    color: #fff;
    border-radius: 8px;
    line-height: 16px;
    cursor: pointer;
  }
  .reg_table_modalBox_foot>div button>span:hover{
    background: #fa1f1c;
  }
  .reg_r_btn_modal_c_fontBtn{
    text-align: right;
  }
  .reg_r_btn_modal_c_fontBtn button{
    margin-top: 10px;
    margin-right: 40px;
  }

  /*报告流程*/
  .report_process{
    width: 100%;
    display: none;
  }
  .report_process_search{
    width: 90%;
    margin: 15px auto;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 10px;
  }
  .report_process_search tr td{
    height: 36px;
  }
  .report_process_search input,.report_process select{
    width: 100%;
  }
  .report_process_search tr td:nth-child(1){
    width: 10%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .report_process_search tr td:nth-child(2){width: 23.33%;}
  .report_process_search tr td:nth-child(3){
    width: 10%;
    text-align: center;
    text-align-last: justify;
    padding: 0 5px;
  }
  .report_process_search tr td:nth-child(3)>div{
    text-align: center !important;
    text-align-last: center;
  }
  .report_process_search tr td:nth-child(4){width: 23.33%;}
  .report_process_search tr td:nth-child(5){
    width: 10%;
    text-align: justify;
    text-align-last: justify;
    padding: 0 5px;
  }
  .report_process_search tr td:nth-child(6){width: 23.33%;}
  .report_process_search button{
    width: 70%;
    margin: 0 auto;
    text-align-last: center;
    margin-left: 15%;
    height: 30px;
  }
  .report_process_list{
    width: 90%;
    margin: 0 auto;
  }
  .report_process_list>table tr td{
    background: #eaedf7;
    color: #333;
    font-weight: bold;
  }
  .report_process_list tr td{
    text-align: center;
  }
  .report_process_list table tr td:nth-child(1){width: 10%;}
  .report_process_list table tr td:nth-child(2){width: 10%;}
  .report_process_list table tr td:nth-child(3){
    width: 50%;
  }
  .report_process_list table tr td:nth-child(4){width: 30%;}
  .report_process_list tr{
    border-bottom: 1px solid #ddd;
  }
  .report_process_list tr:nth-child(even){
    background: #f9f9f9;
  }
  .report_process_list_cont{
    height: 410px;
    overflow: auto;
  }


  .click_zk{
    color: #999;
    cursor: pointer;
  }
  .reading_r_c_l_center>h1>p{
    display: inline-block;
    float: right;
  }
  .reading_r_c_l_center>h1>p select{
    width: 100px;
  }
  .reading_r_c_l_center>h1>p button{
    width: 70px;
    height: 24px;
    line-height: 24px;
    padding: 0;
    font-size: 12px;
  }

  /*八、 input输入带下拉和检索*/
  .drop_down_Top{
    display: inline-block;
    width: 90%;
    height: 26px;
    position: relative;
  }
  .drop_down_Top>input{
    width: 100%;
    height: 100%;
  }
  .drop_down_Top>ul{
    position: absolute;
    left: 0;
    /*top: 32px;*/
    border: 1px solid #ddd;
    width: 100%;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    height: 240px;
    overflow: auto;
    z-index: 1;
    background-color: #fff;
    /*display: none;*/
  }
  .drop_down_Top>ul>li{
    border-bottom: 1px solid #ddd;
    padding: 6px 10px;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    line-height: 20px;
    cursor: pointer;
  }
  .drop_down_Top>ul.top{
    bottom: 24px !important;
  }

  .tree_down>li a img{
    transform: rotate(0deg);
  }
  .tree_down>li>ul{
    display: none;
  }
  .tree_down>li>ul>li>ul{
    display: none;
  }
</style>


